﻿using Se.Log;
using Se.Model;
using Se.Model.GameModel.Character;
using Se.Model.Generator;
using Se.Protocol;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace SeClient
{
    public class GameController : IClientReceived
    {
        public void PtRequest_LoginOK(long accountId, string name, string message)
        {
            SeLog.Info("收到回复:accountId {0}, message {1}", accountId, message);

            var account = new Account() { ID = accountId, Name = name };
            GameWorld.Account = account;
        }

        public void PtRequest_UpdateChatMsg(IList<ChatMsg> content)
        {
            if (content.Count > 0)
                SeLog.Warn(content[0].Msg);
        }


        public void PtRequest_ErrorInfo(int errorType, string msg)
        {
            SeLog.Error("ErrorInfo: errorType:{0},msg:{1}", errorType, msg);
        }


        public void PtRequest_RegisterOK(long accountId, string userName)
        {
            SeLog.Info("收到回复：userName {0}", userName);
        }


        public void PtRequest_CreatePlayerSuccess(long id, string name, int roleTypeID)
        {

        }
    }
}
